package win.smartown.mistyle.util;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;

/**
 * Created by smartown on 2017/3/18.
 * <br>
 * Description:
 */
public class JumpUtil {

    public static <T extends Activity> void startActivity(Activity activity, Class<T> activityClass, String title) {
        startActivity(activity, activityClass, title, null);
    }

    public static <T extends Activity> void startActivity(Activity activity, Class<T> activityClass, String title, Bundle bundle) {
        Intent intent = new Intent(activity, activityClass);
        intent.putExtra("title", title);
        intent.putExtra("extra", bundle);
        activity.startActivity(intent);
    }

}
